<html dropeffect="none" class="js  is-AppPromotionBarVisible cssanimations csstransforms csstransitions flexbox no-touchevents" style="" lang="zh-CN"><head>
<meta charset="utf-8">

<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="renderer" content="webkit">
<meta http-equiv="X-ZA-Response-Id" content="000d1b03f3c7b893">
<meta http-equiv="X-ZA-Experiment" content="default:None">

<title>{{$user->username}} 的关注者</title>
<style>
	*{
		padding:0px;
		margin:0px;
	}
	ul,li{
		list-style: none;
	}
	a{
		border:none;
	}
	a:link{
		color: black;
	}
	a:hover{
		color:#225599;
	}
</style>
<meta name="apple-itunes-app" content="app-id=432274380">


<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<meta http-equiv="mobile-agent" content="format=html5;url=https://www.zhihu.com/">
<meta id="znonce" name="znonce" content="29530580837446aebb63cd271f2ff040">



<link rel="apple-touch-icon" href="/zhihu/home/images/touch-icon-152.87c020b9.png" sizes="152x152">
<link rel="apple-touch-icon" href="/zhihu/home/images/touch-icon-120.496c913b.png" sizes="120x120">
<link rel="apple-touch-icon" href="/zhihu/home/images/touch-icon-76.dcf79352.png" sizes="76x76">
<link rel="apple-touch-icon" href="/zhihu/home/images/touch-icon-60.9911cffb.png" sizes="60x60">


<link rel="shortcut icon" href="/zhihu/home/images/favicon.ico" type="image/x-icon">

<link rel="search" type="application/opensearchdescription+xml" href="./xml/search.xml" title="知乎">
<link rel="stylesheet" href="/zhihu/home/Css/z.09d0fc1b.css">
<link href="/zhihu/home/dist/css/bootstrap.min.css" rel="stylesheet">
<script src="/zhihu/home/dist/js/jquery-1.11.1.min.js"></script>
<script src="/zhihu/home/dist/js/bootstrap.min.js"></script>
<script type="text/javascript" charset="utf-8" src="/zhihu/UTF/ueditor.config.js"></script>
<script type="text/javascript" charset="utf-8" src="/zhihu/UTF/ueditor.all.min.js"> </script>
<!--建议手动加在语言，避免在ie下有时因为加载语言失败导致编辑器加载失败-->
<!--这里加载的语言文件会覆盖你在配置项目里添加的语言类型，比如你在配置项目里配置的是英文，这里加载的中文，那最后就是中文-->
<script type="text/javascript" charset="utf-8" src="/zhihu/UTF/lang/zh-cn/zh-cn.js"></script>




<!--[if lt IE 9]>
<script src="https://static.zhihu.com/static/components/respond/dest/respond.min.js"></script>
<link href="https://static.zhihu.com/static/components/respond/cross-domain/respond-proxy.html" id="respond-proxy" rel="respond-proxy" />
<link href="/static/components/respond/cross-domain/respond.proxy.gif" id="respond-redirect" rel="respond-redirect" />
<script src="/static/components/respond/cross-domain/respond.proxy.js"></script>
<![endif]-->
<script src="/zhihu/home/Scripts/instant.14757a4a.js"></script>

<style>
.zm-item-answer-author-info a.collapse {margin-top: 0}
</style>

</head>

<body class="zhi ">



<div role="navigation" class="zu-top" data-za-module="TopNavBar">
<div class="zg-wrap modal-shifting clearfix" id="zh-top-inner">
<a href="/" class="zu-top-link-logo" id="zh-top-link-logo" data-za-c="view_home" data-za-a="visit_home" data-za-l="top_navigation_zhihu_logo">知乎</a>

<div class="top-nav-profile">
<a href="/people/sun-jian-jian-93" class="zu-top-nav-userinfo ">
<span class="name">孙建建</span>
<img class="Avatar" src="/zhihu/home/images/da8e974dc_s.jpg" srcset="/zhihu/home/images/da8e974dc_xs.jpg 2x" alt="孙建建">
<span id="zh-top-nav-new-pm" class="zg-noti-number zu-top-nav-pm-count" style="visibility:hidden" data-count="0">

</span>
</a>
<ul class="top-nav-dropdown" id="top-nav-profile-dropdown">
<li>
<a href="/people/sun-jian-jian-93">
<i class="zg-icon zg-icon-dd-home"></i>我的主页
</a>
</li>

<li>
<a href="/inbox">
<i class="zg-icon zg-icon-dd-pm"></i>私信
<span id="zh-top-nav-pm-count" class="zu-top-nav-pm-count zg-noti-number" style="visibility:hidden" data-count="0">

</span>
</a>
</li>
<li>
<a href="/settings">
<i class="zg-icon zg-icon-dd-settings"></i>设置
</a>
</li>
<li>
<a href="/logout">
<i class="zg-icon zg-icon-dd-logout"></i>退出
</a>
</li>
</ul>

</div>



<button class="zu-top-add-question" id="zu-top-add-question">提问</button>


<div role="search" id="zh-top-search" class="zu-top-search">
<form method="GET" action="/search" id="zh-top-search-form" class="zu-top-search-form">



<input name="type" value="content" type="hidden">
<label for="q" class="hide-text">知乎搜索</label><input class="zu-top-search-input" id="q" name="q" autocomplete="off" value="" placeholder="搜索你感兴趣的内容..." type="text">
<button type="submit" class="zu-top-search-button"><span class="hide-text">搜索</span><span class="sprite-global-icon-magnifier-dark"></span></button>
</form>
</div>



<div id="zg-top-nav" class="zu-top-nav">
<ul class="zu-top-nav-ul zg-clear">

<li class="top-nav-topic-selector zu-top-nav-li " id="zh-top-nav-topic">
<a class="zu-top-nav-link" href="/topic" id="top-nav-dd-topic">首页</a>
</li>



<li class="top-nav-topic-selector zu-top-nav-li " id="zh-top-nav-topic">
<a class="zu-top-nav-link" href="/topic" id="top-nav-dd-topic">话题</a>
</li>

<li class="zu-top-nav-li " id="zh-top-nav-explore">
<a class="zu-top-nav-link" href="/explore">发现</a>
</li>

<li class="top-nav-noti zu-top-nav-li ">
<a class="zu-top-nav-link" href="javascript:;" id="zh-top-nav-count-wrap" role="button"><span class="mobi-arrow"></span>消息</a>
</li>



</ul>
<div class="zu-top-nav-live zu-noti7-popup zg-r5px no-hovercard" id="zh-top-nav-live-new" role="popup" tabindex="0">
<div class="zu-top-nav-live-inner zg-r5px">
<div class="zu-top-live-icon">&nbsp;</div>
<div class="zu-home-noti-inner" id="zh-top-nav-live-new-inner">
<div class="zm-noti7-popup-tab-container clearfix" tabindex="0">
<button class="zm-noti7-popup-tab-item message">
<span class="icon">消息</span>
</button>
<button class="zm-noti7-popup-tab-item user">
<span class="icon">用户</span>
</button>
<button class="zm-noti7-popup-tab-item thanks">
<span class="icon">赞同和感谢</span>
</button>
</div>
</div>
<div class="zm-noti7-frame-border top"></div>
<div class="zm-noti7-frame">
<div class="zm-noti7-content message">
<div class="zm-noti7-content-inner">
<div class="zm-noti7-content-body">
<div class="zm-noti7-popup-loading">
<span class="noti-spinner-loading"></span>
</div>
</div>
</div>
</div>
<div class="zm-noti7-content user" style="display:none;">
<div class="zm-noti7-content-inner">
<div class="zm-noti7-content-body">
<div class="zm-noti7-popup-loading">
<span class="noti-spinner-loading"></span>
</div>
</div>
</div>
</div>
<div class="zm-noti7-content thanks" style="display:none;">
<div class="zm-noti7-content-inner">
<div class="zm-noti7-content-body">
<div class="zm-noti7-popup-loading">
<span class="noti-spinner-loading"></span>
</div>
</div>
</div>
</div>
</div>
<div class="zm-noti7-frame-border bottom"></div>
<div class="zm-noti7-popup-footer">
<a href="/notifications" class="zm-noti7-popup-footer-all zg-right">查看全部 »</a>
<a href="/settings/notification" class="zm-noti7-popup-footer-set" title="通知设置"><i class="zg-icon zg-icon-settings"></i></a>
</div>
</div>
</div>

</div>

</div>
</div>


<div class="zu-global-notify" id="zh-global-message" style="display:none">
<div class="zg-wrap">
<div class="zu-global-nitify-inner">
<a class="zu-global-notify-close" href="javascript:;" title="关闭" name="close">x</a>
<span class="zu-global-notify-icon"></span>
<span class="zu-global-notify-msg"></span>
</div>
</div>
</div>
<div class="zg-wrap zu-main clearfix " role="main">
<div class="zu-main-content">
<div style = "border:1px solid #cccccc;width:600px;">
	<div style = "width:100px;float:left">
		<img src = "xxoo" style = "width:100px;"/>
	</div>
	<span><span><span style = "color:#fff"></span></span></span>
	<div style = "width:450px;float:left;margin-left:10px;">
		<ul>
			<li style = "font-weight:bold;font-size:16px;margin-bottom:10px;">{{$user->username}}</li>
			<li style = "color:grey;margin-bottom:10px;">{{$detail->professional}}</li>
			<li style = "color:grey;margin-bottom:10px;">{{$detail->address}}</li>
			<li style = "color:grey;margin-bottom:10px;">{{$detail->education}}</li>
			<li style = "color:grey;margin-bottom:10px;border-top:1px solid #cccccc">{{$detail->introduction}}</li>
		</ul>
		<!-- 此处user_id为用户id value为session('id')值-->
		<input id="user_id" name="user_id" value="{{$user_id}}" type="hidden">
		<input id="id" name="id" value="{{$id}}" type="hidden">
		<button type="button" class="btn btn-success follow_him" style="margin-left:380px;margin-bottom:40px;"><?php echo empty(DB::table("peoplefocus")->where("user_id",$user_id)->where("other_id",$id)->first())?"关注他":"取消关注" ?></button><input type = "hidden" value = "{{$id}}" />
	</div>
	<p style = "clear:both"></p>
</div>
	<div style = "border:1px solid grey;width:600px;height:30px;">
		<ul style = "text-align:center;margin-top:2px;">
			<li id = "questions" style = "float:left;cursor:pointer;width:100px;font-size:14px;font-weight:bold;border-right:1px solid grey;">提问({{$question_num}})</li>
			<li id = "answers" style = "float:left;width:100px;font-size:14px;font-weight:bold;border-right:1px solid grey;cursor:pointer">回答(@if(!empty($answers)){{$answer_num}} @else 0 @endif)</li>
			<li id = "favors" style = "float:left;cursor:pointer;width:100px;font-size:14px;font-weight:bold;border-right:1px solid grey;">关注({{$favor_num}})</li>
		</ul>
		<p style = "clear:both"></p>
	</div>
	<div style = "width:600px;border-radius:5px;margin-top:10px;border:1px solid #cccccc">
		<div style= "border-bottom:1px solid #cccccc;font-size:15px;color:#225599">
			{{$user->username}}的关注者
		</div>
		<div>
			@foreach($follows as $k=>$v)
			<div style = "margin-bottom:10px;border-bottom:1px solid #cccccc;position:relative">
					<span>
						<img style = "width:50px;" src = "{{$follows_info[$v->id]->user_portrait}}" />
					</span>
					<span>
						<span style = "color:#225599;position:absolute;top:0px;left:60px;">
							{{$follows_info[$v->id]->nickname}}
						</span><br />
						<span style = "color:#grey;position:absolute;top:16px;left:60px;">
							{{$follows_info[$v->id]->professional}}
						</span>
						<span style = "color:#grey;position:absolute;top:32px;left:60px;">
						{{$follows_info_num[$v->id]}}关注者/{{$follows_question_num[$v->id]}}提问/{{$follows_answer_num[$v->id]}}回答
						</span>
					</span>
					<span>
						<button type="button" class="btn btn-success follow_him" style="margin-left:380px;margin-bottom:40px;width:100px;height:5px;font-size:10px;padding-bottom:15px;position:absolute;top:10px;left:97px;"><?php echo empty(DB::table("peoplefocus")->where("user_id",$user_id)->where("other_id",$follows_info[$v->id]->user_id)->first())?"关注他":"取消关注" ?></button><input type = "hidden" value = "{{$follows_info[$v->id]->user_id}}" />
					</span>
			</div>	
			@endforeach
		</div>
	</div>
</div>
<script>
	var user_id = document.getElementById("user_id").value;
	var id = document.getElementById("id").value;
	var obj1 = document.getElementById("questions");
	var obj2 = document.getElementById("answers");
	var obj3 = document.getElementById("favors");
	obj1.onclick = function(){
		location.href = "/people/questions/"+id;
	}
	obj2.onclick = function(){
		location.href = "/people/answers/"+id;
	}
	obj3.onclick = function(){
		location.href = "/people/favors/"+id;
	}

	//关注他
	var follow_him = document.getElementsByClassName("follow_him");
	for(var j = 0;j<follow_him.length;j++)
	{
		follow_him[j].onclick = function(){
				var him_id = this.nextElementSibling.value;
				var obj = new XMLHttpRequest();
				obj.onreadystatechange = function(){
						if(obj.readyState ==4 && obj.status == 200){
							follow_him_value = obj.responseText;
							}
						}
						obj.open('GET','/follow_him?user_id= '+user_id+'&other_id='+him_id,false);
						obj.send();
						if(follow_him_value == 1)
						{
							this.textContent = "取消关注";
						}
						if(follow_him_value == 0)
						{	
							this.textContent = "关注他";
						}

		}
	}
</script>
</body>